<!DOCTYPE html>
<html>

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">


    <title>{% block title %}{% endblock %}</title>

    <link rel="shortcut icon" href="/static/hplus/favicon.ico">
    <link href="/static/hplus/css/bootstrap.min.css?v=3.3.6" rel="stylesheet">
    <link href="/static/hplus/css/font-awesome.min.css" rel="stylesheet">
    <link href="/static/flat/css/flat-ui.min.css" rel="stylesheet">
    {% block styles %}{% endblock %}


</head>

<body class="gray-bg">
<nav class="navbar navbar-default navbar-inverse">
    <div class="container-fluid">
        <!-- Brand and toggle get grouped for better mobile display -->
        <div class="navbar-header">
            <button type="button" class="navbar-toggle collapsed" data-toggle="collapse"
                    data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
                <span class="sr-only">Toggle navigation</span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
            </button>
            <a class="navbar-brand" href="#">
                <img width="20" height="20" alt="Brand"
                     src=""/>
            </a>
            <a class="navbar-brand" href="/">titarzhe的博客</a>
        </div>

        <!-- Collect the nav links, forms, and other content for toggling -->
        <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
            <ul class="nav navbar-nav">

            </ul>
            <ul class="nav navbar-nav navbar-right">

                {% if user == nil || user.Id == nil %}
                    <li>
                        <a href="/login">登录</a>
                    </li>
                    <li>
                        <a href="/register">注册</a>
                    </li>
                {% else %}
                    <li>
                        <a href="/logout">{{ user.Username }},你好</a>
                    </li>
                {% endif %}

                <li class="dropdown">
                    <a href="#" class="btn btn-inverse dropdown-toggle" data-toggle="dropdown" role="button"
                       aria-haspopup="true" aria-expanded="false">加密</a>
                    <ul class="dropdown-menu">
                        <li><a href="/encrypt/md5">md5</a></li>
                        <li><a href="#">Another action</a></li>
                        <li><a href="#">Something else here</a></li>
                        <li role="separator" class="divider"></li>
                        <li><a href="#">Separated link</a></li>
                    </ul>
                </li>
                <li class="dropdown">
                    <a class="btn btn-inverse dropdown-toggle" data-toggle="dropdown" role="button"
                       aria-haspopup="true">聊天</a>
                    <ul class="dropdown-menu">
                        <li><a href="/chat/room">聊天室</a></li>
                        <li><a href="#">Another action</a></li>
                        <li><a href="#">Something else here</a></li>
                        <li role="separator" class="divider"></li>
                        <li><a href="#">Separated link</a></li>
                    </ul>
                </li>
                <li class="dropdown">
                    <a href="#" class="btn btn-inverse dropdown-toggle" data-toggle="dropdown" role="button"
                       aria-haspopup="true" aria-expanded="false">Dropdown</a>
                    <ul class="dropdown-menu">
                        <li><a href="#">Action</a></li>
                        <li><a href="#">Another action</a></li>
                        <li><a href="#">Something else here</a></li>
                        <li role="separator" class="divider"></li>
                        <li><a href="#">Separated link</a></li>
                    </ul>
                </li>
            </ul>
        </div><!-- /.navbar-collapse -->
    </div><!-- /.container-fluid -->
</nav>
{% block body %}{% endblock %}
<!-- 全局js -->
<script src="/static/hplus/js/jquery.min.js?v=2.1.4"></script>
<script src="/static/hplus/js/bootstrap.min.js?v=3.3.6"></script>
{% block scripts %}{% endblock %}

</body>

</html>